home *** CD-ROM | disk | FTP | other *** search
- Path: news1.intercall.com!usenet
- From: engevar@intercall.com (Steven Ovits)
- Newsgroups: comp.lang.c
- Subject: Re: This should really be a simple question for you C-freaks...
- Date: Thu, 04 Apr 1996 19:45:16 GMT
- Organization: Intercall Inc.
- Message-ID: <4k0vd0$roo@news1.intercall.com>
- References: <4jrue1$gsu@nyheter.chalmers.se>
- NNTP-Posting-Host: ts2-105.intercall.com
- X-Newsreader: Forte Free Agent 1.0.82
-
- Tobias Nilsson <tb9593@ios.chalmers.se> wrote:
-
- >Well, even a damn good assembler-programmer runs into trouble,
- >sometimes... ;)
-
- >Anyway... I'm just trying to read the keyboard without having the
- >characters displayed on the f-cking screen! Just as that! But I've
- >tried getchar, scanf, fun.01 int 21h... but they all display them...
- >I'm sure you had this question before... but I was playing with myself
- >that time, so I missed it... I want just pure ASCII, please help me!
- >(Ps... This is on the PC-platform... And I'm really fresh on C... and I
- >hope there is a standard function for this... ;)
-
- >Thanx!!!
- >
-
- Sorry. There is purposely no standard function to do this.
- In fact, it's much worse. There's no standard way to get any
- characters from the keyboard without pressing the enter key.
- This is because C needs to be portable to multi-terminal
- environments that don't communicate with the host except
- at defined times--such as when you press Enter.
-
- Even on the PC, getch() will only read the characters from
- the keyboard after the Enter key is pressed. You need to use
- a non standard method to get characters as they are pressed,
- regardless of whether you want them echoed to the screen or not.
- Every compiler vendor has a function for this. Look for it
- under getkbd(), bioskey(), or some similar name.
-
-
-